/*
 * @Author: WuFeng <763467339@qq.com>
 * @Date: 2022-03-22 12:12:49
 * @LastEditTime: 2023-06-06 16:12:47
 * @LastEditors: WuFeng <763467339@qq.com>
 * @Description: vuex getters
 * @FilePath: \vue3-element-plus-web\src\store\getters.js
 * @Copyright 版权声明
 */
const getters = {
  roleSwitch: (state) => state.layout.roleSwitch, // 可切换多角色
  layoutType: (state) => state.layout.layoutType, // 布局类型
  multilTheme: (state) => state.layout.multilTheme, // 是否展示多主题切换
  multilLanguage: (state) => state.layout.multilLanguage, // 是否展示多语言切换
  sysThemeEnum: (state) => state.layout.sysThemeEnum, // 系统主题 - 列表
  sysTheme: (state) => state.layout.sysTheme, // 系统主题
  language: (state) => state.language.lang, // 系统语言
  sidebar: (state) => state.app.sidebar,
  device: (state) => state.app.device,
  token: (state) => state.user.token,
  userType: (state) => state.user.userType,
  userInfo: (state) => state.user.userInfo,
  avatar: (state) => state.user.avatar,
  name: (state) => state.user.name,
  menus: (state) => state.user.menus,
  menusLoad: (state) => state.user.menusLoad,
  visitedViews: (state) => state.tagsView.visitedViews,
  cachedViews: (state) => state.tagsView.cachedViews,
  permissionRouters: (state) => state.permission.routers, // 所有路由
  permissionRoutersMap: (state) => state.permission.routersMap, // 所有末级路由的map，key为路由的name
  permissionAuthRouters: (state) => state.permission.authRouters, //权限系统菜单
  addRouters: (state) => state.permission.addRouters, // 动态生成的动态路由
  iframeHref: (state) => state.permission.iframeHref, //iframe模式引用的src
  sidebarTopActive: (state) => state.permission.sidebarTopActive, //当前选中的头部导航
  drawerVisible: (state) => state.drawer.visible, // 抽屉是否展示
  drawerReloadPage: (state) => state.drawer.reloadPage, // 是否重载页面标识 ， true：重载 false：不重载
  drawerCurrent: (state) => state.drawer.current, // 当前打开的抽屉
  drawerHistory: (state) => state.drawer.history, // drawer跳转的历史栈
  drawerKeepAlive: (state) => state.drawer.drawerKeepAlive, // 被 keep-alive 缓存的抽屉组件， 一层为模块组件，二层为模块内页面组件
  drawerLoading: (state) => state.drawer.loading, // 抽屉 loading 状态
  columnSettingsDrawerVisible: (state) => state.columnSettingsDrawer.visible, // 列设置 抽屉是否展示
  columnSettingsDrawerLoading: (state) => state.columnSettingsDrawer.loading, // 列设置 抽屉 loading 状态
  dictData: (state) => state.dictData.dictData, // 字典存储器
  // 选择的表集合
  genderCodeTableRowSet: (state) => state.genderCode.tableRowSet,
  // 模块配置信息
  genderCodeModuleInfo: (state) => state.genderCode.moduleInfo,
  // 当前正在配置的字段的下标， 对应 moduleInfo.column[settingColumnIndex]
  genderCodeSettingColumnIndex: (state) => state.genderCode.settingColumnIndex
}
export default getters
